package cn.service.impl;

import cn.entity.SysLog;
import cn.mapper.SysLogMapper;
import cn.service.SysLogService;
import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

@Service
@Transactional//事务开启
public class SysLogServiceImpl extends BaseServiceImpl<SysLog> implements SysLogService {
    @Autowired
    SysLogMapper sysLogMapper;

    @Override
    public PageInfo<SysLog> selectPage(int pageNum, int pageSize, String description) {
        PageHelper.startPage(pageNum,pageSize);
        return new PageInfo<SysLog>(sysLogMapper.select(new SysLog()));
    }
}
